<div id="content">
	<div class="row s_page_title" *ngIf="pageType ==='new'">
		<sa-big-breadcrumbs [items]="['系统基础管理','库存管理','新增库存']" icon="fa fa-list" class="col-xs-12 col-sm-7 col-md-7 col-lg-4"></sa-big-breadcrumbs>
	</div>
	<div class="row s_page_title" *ngIf="pageType ==='updata'">
		<sa-big-breadcrumbs [items]="['系统基础管理','库存管理','编辑库存']" icon="fa fa-list" class="col-xs-12 col-sm-7 col-md-7 col-lg-4"></sa-big-breadcrumbs>
	</div>
	<div class="s_page_wrap">
		<div class="page-header">
			<h1 class="page_detail_title">{{page_title}}设备</h1>
		</div>
		<div class="row" style="margin-top:5px;">
			<div class="col-xs-12">
				<form id="roleForm" class="form-horizontal" (ngSubmit)="onSubmit()" novalidate="novalidate" [saBootstrapValidator]="validatorOptions">

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">生产时间<sup>*</sup></label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.productTime' [attr.roleId]='roleId' name="productTime" id="productTime" type="text" placeholder="生产时间" autocomplete="off" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">设备状态</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<select class="form-control" name="status" [(ngModel)]='page.status'>
									<option value="0">库存</option>
									<option value="1">已发货</option>
								</select>
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">产品编号<sup>*</sup></label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.productNo' name="productNo" type="text" placeholder="产品编号" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">设备ID<sup>*</sup></label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.deviceId' name="deviceId" type="text" placeholder="设备ID" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">SIM卡号</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.iccid' name="iccid" type="text" placeholder="SIM卡号" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">产品型号</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.productType' name="productType" type="text" placeholder="产品型号" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">通道信息</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.productChannel' name="productChannel" type="text" placeholder="通道信息" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">是否带电池</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<select class="form-control" name="hasLIB" [(ngModel)]='page.hasLIB'>
									<option value="1">是</option>
									<option value="0">否</option>
								</select>
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">GPS供应商</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.gpsProducer' name="gpsProducer" type="text" placeholder="GPS供应商" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">SIM供应商</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.simProducer' name="simProducer" type="text" placeholder="SIM供应商" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">MES编号</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.mesNumber' name="mesNumber" type="text" placeholder="MES编号" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">主机检验结果</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<select class="form-control" name="resultStatus" [(ngModel)]='page.resultStatus'>
									<option value="">请选择</option>
									<option value="1">合格</option>
									<option value="2">不合格</option>
								</select>
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">发货时间</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.sendTime' id="sendTime" name="sendTime" type="text" placeholder="发货时间" autocomplete="off" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">发货地址</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.sendAddress' name="sendAddress" type="text" placeholder="发货地址" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">发货公司</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.sendCompany' name="sendCompany" type="text" placeholder="发货公司" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">硬件版本</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.hwVersion' name="hwVersion" type="text" placeholder="硬件版本" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">软件版本</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.swVersion' name="swVersion" type="text" placeholder="软件版本" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">BootLoader版本</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.blVersion' name="blVersion" type="text" placeholder="BootLoader版本" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">主机版本号</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.mbVersion' name="mbVersion" type="text" placeholder="主机版本号" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">备注</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.remake' name="remake" type="text" placeholder="备注" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">出库人员</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.outUser' name="outUser" type="text" placeholder="出库人员" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">录入时间</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.creatTime' name="creatTime" id="creatTime" type="text" placeholder="录入时间" autocomplete="off" />
							</div>
						</div>
					</div>

					<div class="form-group">
						<label class="control-label col-sm-1 no-padding-right">更新时间</label>
						<div class="col-sm-10">
							<div class="clearfix">
								<input class="form-control" [(ngModel)]='page.updateTime' name="updateTime" id="updateTime" type="text" placeholder="更新时间" autocomplete="off" />
							</div>
						</div>
					</div>


					<div class="center">
						<button type="submit" class="btn btn-primary" *ngIf='page_title === "新增"'>添加</button>
						<button type="submit" class="btn btn-primary" *ngIf='page_title === "编辑"'>保存</button>
						<button type="button" (click)='goBack()' class="btn default">返回</button>
					</div>
				</form>
				<div class="hr hr-dotted"></div>
			</div>
		</div>
	</div>
</div>